home *** CD-ROM | disk | FTP | other *** search
/ Carousel / CAROUSEL.cdr / mactosh / code / p_serlib.sit / Serial Library Source Code / makefile < prev    next >
Makefile  |  1989-07-27  |  4KB  |  142 lines

  1. #    Makefile for compiling Serial Driver routines
  2. #    by Atul Butte
  3. #    Copyright ⌐ 1989 by Microsoft Corporation
  4. #    All Rights Reserved
  5. #
  6. #    version 1.0
  7. #
  8. #    MPW 3.0 C Compiler required
  9.  
  10. #    Serial Driver routines
  11.  
  12. SerialRoutines                = ╢
  13.         serial.charArrived.dll ╢
  14.         serial.clearBreak.dll ╢
  15.         serial.close.dll ╢
  16.         serial.configure.dll ╢
  17.         serial.open.dll ╢
  18.         serial.read.dll ╢
  19.         serial.readFile.dll ╢
  20.         serial.readFileTilStr.dll ╢
  21.         serial.readTilStr.dll ╢
  22.         serial.resetBuffer.dll ╢
  23.         serial.setBreak.dll ╢
  24.         serial.setBuffer.dll ╢
  25.         serial.waitTilStr.dll ╢
  26.         serial.write.dll ╢
  27.         serial.writeFile.dll
  28.  
  29. #    Transforming object file into a .dll file
  30. #    Note: although CODE/REGISTER routines must be CODE resources, we
  31. #    cannot link and create a CODE resource, because the linker thinks we
  32. #    want to compile an application, which we don't want to do.
  33. #    Thus, we link and create a XDLL resource, and this resource is converted
  34. #    into a CODE resource in the final step (see serial.r).
  35. #
  36. #    dll, by the way, stands for downloadable library. We suffix the file names
  37. #    with dll so we can use the following dependency for all the files with routines.
  38.  
  39. .dll                        ─    .dll.c.o
  40.     Link    -o {Default}.dll ╢
  41.             -rt XDLL=0 ╢
  42.             -m MAIN ╢
  43.             -sn MAIN={Default} ╢
  44.             -sg {Default} ╢
  45.             -t XLLB ╢
  46.             -c XCEL ╢
  47.             {Default}.dll.c.o ╢
  48.             "{Libraries}Interface.o" ╢
  49.             error.c.o
  50.  
  51. #    Transforming the source code into an object file
  52. #    Note: We have to do this in two compiles, because of a bug in the
  53. #    C compiler, which doesn't handle string concatenation correctly.
  54.  
  55. .dll.c.o                    ─    .dll.c
  56.     C        {Default}.dll.c ╢
  57.             -e2 | ╢
  58.     C        -o {Default}.dll.c.o ╢
  59.             -t ╢
  60.             -b2 ╢
  61.             -r
  62.  
  63. #    The final step
  64.  
  65. "serial library"            ──    {SerialRoutines} serial.r
  66.     Rez        serial.r ╢
  67.             -a ╢
  68.             -c "XCEL"╢
  69.             -t "XLM " ╢
  70.             -o {Targ}
  71.  
  72. #    The individual Serial Library routines
  73.  
  74. serial.charArrived.dll        ──    error.c.o error.h serial.h ╢
  75.                                 get_port.c get_port.h
  76.  
  77. serial.clearBreak.dll        ──    error.c.o error.h serial.h ╢
  78.                                 get_port.c get_port.h
  79.  
  80. serial.close.dll            ──    error.c.o error.h
  81.  
  82. serial.configure.dll        ──    error.c.o error.h serial.h ╢
  83.                                 get_port.c get_port.h
  84.  
  85. serial.open.dll                ──    error.c.o error.h serial.h
  86.  
  87. serial.read.dll                ──    error.c.o error.h serial.h ╢
  88.                                 get_port.c get_port.h ╢
  89.                                 get_read_flags.c get_read_flags.h
  90.  
  91. serial.readFile.dll            ──    error.c.o error.h serial.h ╢
  92.                                 get_port.c get_port.h ╢
  93.                                 get_read_flags.c get_read_flags.h
  94.  
  95. serial.readFileTilStr.dll    ──    error.c.o error.h serial.h ╢
  96.                                 get_port.c get_port.h ╢
  97.                                 interpret.c interpret.h ╢
  98.                                 get_read_flags.c get_read_flags.h
  99.  
  100. serial.readTilStr.dll        ──    error.c.o error.h serial.h ╢
  101.                                 get_port.c get_port.h ╢
  102.                                 interpret.c interpret.h ╢
  103.                                 get_read_flags.c get_read_flags.h
  104.  
  105. serial.resetBuffer.dll        ──    error.c.o error.h serial.h ╢
  106.                                 get_port.c get_port.h
  107.  
  108. serial.setBreak.dll            ──    error.c.o error.h serial.h ╢
  109.                                 get_port.c get_port.h
  110.  
  111. serial.setBuffer.dll        ──    error.c.o error.h ╢
  112.                                 serial.h ╢
  113.                                 get_port.c get_port.h
  114.  
  115. serial.waitTilStr.dll        ──    error.c.o error.h ╢
  116.                                 serial.h ╢
  117.                                 get_port.c get_port.h ╢
  118.                                 interpret.c interpret.h ╢
  119.                                 get_read_flags.c get_read_flags.h
  120.  
  121. serial.write.dll            ──    error.c.o error.h ╢
  122.                                 serial.h ╢
  123.                                 get_port.c get_port.h ╢
  124.                                 interpret.c interpret.h ╢
  125.                                 absorb_echo.c absorb_echo.h ╢
  126.                                 get_write_flags.c get_write_flags.h
  127.  
  128. serial.writeFile.dll        ──    error.c.o error.h ╢
  129.                                 serial.h ╢
  130.                                 absorb_echo.c absorb_echo.h ╢
  131.                                 get_write_flags.c get_write_flags.h
  132.  
  133. #    The error handling routine
  134.  
  135. error.c.o                    ─    error.c error.h
  136.     C        error.c ╢
  137.             -e2 | ╢
  138.     C        -o error.c.o ╢
  139.             -t ╢
  140.             -b2 ╢
  141.             -r
  142.